import { ref } from 'vue'

// 侧边栏收起状态管理
const isSideMenuCollapsed = ref(true)

export function useSideMenu() {
    const toggleSideMenu = () => {
        isSideMenuCollapsed.value = !isSideMenuCollapsed.value
    }

    const setSideMenuCollapsed = (collapsed: boolean) => {
        isSideMenuCollapsed.value = collapsed
    }

    return {
        isSideMenuCollapsed,
        toggleSideMenu,
        setSideMenuCollapsed
    }
} 